<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <jsp:include page="/static/common/easyui_header.jsp"/>
    <script type="text/javascript" src="/static/js/member.js"></script>
</head>
<body>
<div style="background-color: white">
    <div id="member_datagrid_toolbar" style="background-color: white">
        <a href="#" class="easyui-linkbutton" iconCls="icon-add" data-options="plain:true" data-cmd="addMember">添加</a>
        <a href="#" class="easyui-linkbutton" iconCls="icon-edit" data-options="plain:true" data-cmd="editMember">编辑</a>
        <a href="#" class="easyui-linkbutton" iconCls="icon-remove" data-options="plain:true" data-cmd="removeMember">删除</a>
        <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="reloadMember">刷新</a>
        <%--<a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="exportMemberInfos">导入</a>--%>
        <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="exportMemberInfos">导出</a>
        <a id="loss" href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="lossCard">挂失</a>
        <a id="unloss" href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="cancelLossCard">取消挂失</a>
        <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="modifyPassword">修改密码</a>
        <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="resetPassword">重置密码</a>
        <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" data-cmd="supplementCard">补卡</a>
        <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-options="plain:true" id="filterMember" data-cmd="openOrClose">筛选会员</a>
        关键词:<input id="keyword" type="easyui-textbox" name="keyword" style="width: 100px;"/>
        <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-cmd="searchMember">搜索</a>
    </div>
    <form id="qo_params_form" method="post">
        <br/>
        注册来源: <input class="easyui-combobox" name="resourceId" id="resourceId"/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        操作员:<input class="easyui-combobox" name="operatorId" id="operatorId"/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        <div id="openOrClose" hidden="hidden">
            <br/>
            会员等级:<input class="easyui-combobox" name="levelId" id="levelId"
                        data-options="valueField:'id',textField:'name',url:'/level/listAll'"/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            &nbsp;&nbsp;&nbsp;会员分组:<input class="easyui-combobox" name="groupId" id="groupId"
                                          data-options="valueField:'id',textField:'name',url:'/group/listAll'"/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            会员标签:<input class="easyui-combobox" name="tagIds" id="tagIds"
                        data-options="valueField:'id',multiple:true,textField:'name',url:'/tag/listAll'"/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <a href="#" class="easyui-linkbutton" iconCls="icon-reload" data-cmd="searchMember2">搜索</a>
        </div>

    </form>
    <table id="member_datagrid" class="easyui-datagrid"></table>
    <div>
        移动至分组:<input class="easyui-combobox" name="groupId" id="moveGroup"/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        打标签:<input class="easyui-combobox" name="tagId" id="addTag"/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    </div>
    <div id="member_edit_dialog" class="easyui-dialog" style="width: '200px';height: '200px'" closed="true"
         buttons="#bottom_buttons">
        <form id="member_edit_Form" method="post">
            <table>
                <tr>
                    <td><input type="hidden" name="id"/></td>
                    <%--注意不能缺少隐藏域--%>
                </tr>
                <tr>
                    <td>会员卡号</td>
                    <td><input class="easyui-textbox" name="cardSn" id="cardSn"  required="required" /></td>
                    <td>会员姓名</td>
                    <td><input class="easyui-textbox" name="username" required="required"/></td>
                </tr>
                <tr>
                    <td>手机号码</td>
                    <td><input class="easyui-textbox" name="tel" required="required"/></td>
                    <td>会员密码</td>
                    <td><input class="easyui-textbox" name="password" required="required"/></td>
                </tr>
                <tr>
                    <td>会员等级</td>
                    <td><input class="easyui-combobox" name="level.id"
                               data-options="valueField:'id',textField:'name',url:'/level/listAll'"/></td>
                    <td>会员称谓</td>
                    <td>
                        <input class="easyui-combobox" name="gender.id"
                               data-options="valueField:'id',textField:'name',url:'/gender/listAll'"/>
                    </td>
                </tr>
                <tr>
                    <td>开卡金额</td>
                    <td><input class="easyui-textbox" name="initAccount" required="required"/></td>
                    <td>会员生日</td>
                    <td><input class="easyui-datebox" name="birthday"/></td>
                </tr>
                <tr>
                    <td>赠送金额</td>
                    <td><input class="easyui-textbox" name="giftAccount" required="required"/></td>
                    <td>开卡员工</td>
                    <td>
                        <input class="easyui-combobox" name="inputUser.id"  required="required"
                               data-options="valueField:'id',textField:'name',url:'/employee/listAll'"/>
                    </td>
                </tr>
                <tr>
                    <td>支付类型</td>
                    <td>
                        <input class="easyui-combobox" name="payway.id" required="required"
                               data-options="valueField:'id',textField:'name',url:'/payway/listAll'"/>
                    </td>
                    <td>过期日期</td>
                    <td><input class="easyui-datebox" name="deadLine"/></td>
                </tr>
                <tr>
                    <td>会员分组</td>
                    <td>
                        <input class="easyui-combobox" name="mgroup.id"
                               data-options="valueField:'id',textField:'name',url:'/group/listAll'"/>
                    </td>
                    <td>qq号码</td>
                    <td><input class="easyui-textbox" name="qq"/></td>
                </tr>
                <tr>
                    <td>会员微信</td>
                    <td><input class="easyui-textbox" name="wechat"/></td>
                    <td>电子邮箱</td>
                    <td><input class="easyui-textbox" name="email"/></td>
                </tr>
                <tr>
                    <td>会员地址</td>
                    <td><input class="easyui-textbox" name="address"/></td>
                    <td>用户喜好</td>
                    <td><input class="easyui-textbox" name="interest"/></td>
                </tr>
                <tr>
                    <td>推荐人</td>
                    <td>
                        <input class="easyui-combobox" name="recommender.id"
                               data-options="valueField:'id',textField:'username',url:'/member/listAll'"/>
                    </td>
                    <td>备注信息</td>
                    <td><input class="easyui-textbox" name="remark"/></td>
                </tr>
                <tr>
                    <td>提醒</td>
                    <td><input class="easyui-textbox" name="tips"/></td>
                </tr>
            </table>
        </form>
    </div>

    <div id="modify_password_dialog" class="easyui-dialog" closed="true" buttons="#modifyPassword_bottom_buttons">
        <form id="modify_password_form" method="post">
            <table>
                <tr>
                    <td><input type="hidden" name="id"/></td>
                    <%--注意不能缺少隐藏域--%>
                </tr>
                <tr>
                    <td>原密码</td>
                    <td><input class="easyui-textbox" name="oldPassword"/></td>
                </tr>
                <tr>
                    <td>新密码</td>
                    <td><input class="easyui-textbox" name="newPassword"/></td>
                </tr>
                <tr>
                    <td>确认密码</td>
                    <td><input class="easyui-textbox" name="newPassword_again"/></td>
                </tr>
            </table>
        </form>
    </div>
    <div id="bottom_buttons">
        <a class="easyui-linkbutton" data-cmd="save">确定</a>
        <a class="easyui-linkbutton" data-cmd="cancel">取消</a>
    </div>
    <div id="modifyPassword_bottom_buttons">
        <a class="easyui-linkbutton" data-cmd="save_modifyPassword">确定</a>
        <a class="easyui-linkbutton" data-cmd="cancel_modifyPassword">取消</a>
    </div>
</div>
</body>
</html>
